<!DOCTYPE html>
<html lang="en">
<head>
    <!--<meta name="viewport" content="width=device-width,initial-scale=1.0,">-->
    <meta charset="UTF-8">
    <script>
        var fixW=150;
        var screenW=window.screen.width;
        var scale=screenW/fixW;
        var meta=document.createElement("meta");
        meta.setAttribute("name","viewport");
        meta.setAttribute("content","width="+fixW+",initial-scale="+scale+"")
        document.getElementsByTagName("head")[0].appendChild(meta);
    </script>
    <title>适配-固宽</title>
    <style>
        *{
            margin: 0;
            padding: 0;
        }
        #box{
            background: url("images/page2-img9.jpg");
            height: 100px;
        }
    </style>
</head>
<body>
<div id="box"></div>
</body>
</html>